package com.jneagle.xlstool.bzwgjmx.stack.bean.entity;

import com.dwarfeng.subgrade.stack.bean.entity.Entity;
import com.dwarfeng.subgrade.stack.bean.key.LongIdKey;

/**
 * 原始错误信息。
 *
 * @author DwArFeng
 * @since 1.0.0
 */
public class RawErrorInfo implements Entity<LongIdKey> {

    private static final long serialVersionUID = 7564256659117930186L;

    private LongIdKey key;
    private String partNo;
    private String originFileName;
    private String parserName;
    private Integer rowIndex;
    private String errorMessage;

    public RawErrorInfo() {
    }

    public RawErrorInfo(
            LongIdKey key, String partNo, String originFileName, String parserName, Integer rowIndex,
            String errorMessage
    ) {
        this.key = key;
        this.partNo = partNo;
        this.originFileName = originFileName;
        this.parserName = parserName;
        this.rowIndex = rowIndex;
        this.errorMessage = errorMessage;
    }

    @Override
    public LongIdKey getKey() {
        return key;
    }

    @Override
    public void setKey(LongIdKey key) {
        this.key = key;
    }

    public String getPartNo() {
        return partNo;
    }

    public void setPartNo(String partNo) {
        this.partNo = partNo;
    }

    public String getOriginFileName() {
        return originFileName;
    }

    public void setOriginFileName(String originFileName) {
        this.originFileName = originFileName;
    }

    public String getParserName() {
        return parserName;
    }

    public void setParserName(String parserName) {
        this.parserName = parserName;
    }

    public Integer getRowIndex() {
        return rowIndex;
    }

    public void setRowIndex(Integer rowIndex) {
        this.rowIndex = rowIndex;
    }

    public String getErrorMessage() {
        return errorMessage;
    }

    public void setErrorMessage(String errorMessage) {
        this.errorMessage = errorMessage;
    }

    @Override
    public String toString() {
        return "RawErrorInfo{" +
                "key=" + key +
                ", partNo='" + partNo + '\'' +
                ", originFileName='" + originFileName + '\'' +
                ", parserName='" + parserName + '\'' +
                ", rowIndex=" + rowIndex +
                ", errorMessage='" + errorMessage + '\'' +
                '}';
    }
}
